From: Jonas Dreßler Date: Thu, 9 May 2024 08:03:23 +0000 (+0200) Subject: portalHelper: Use default_size instead of set_size_request for size X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~226^2^2~95 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=5aa89fa9e62d20c99afd2eff13901faef96244ad;p=gnome-shell.git portalHelper: Use default_size instead of set_size_request for size GtkWidget.set_size_request() enforces a minimum size, while GtkWidget.set_default_size() simply sets the default size. The docs of set_size_request() say "In most cases, gtk_window_set_default_size() is a better choice for toplevel windows", and in our case it doesn't seem necessary to prohibit the window from having a smaller size, so switch to using the default_width and default_height properties. Part-of: --- diff --git a/js/portalHelper/main.js b/js/portalHelper/main.js index 1716dc979..1a5c644dc 100644 --- a/js/portalHelper/main.js +++ b/js/portalHelper/main.js @@ -113,6 +113,8 @@ class PortalWindow extends Gtk.ApplicationWindow { super._init({ application, title: _('Hotspot Login'), + default_width: 600, + default_height: 450, }); const headerbar = new Gtk.HeaderBar(); @@ -153,7 +155,6 @@ class PortalWindow extends Gtk.ApplicationWindow { this._syncUri(); this.set_child(this._webView); - this.set_size_request(600, 450); this.maximize(); this.present_with_time(timestamp);